package com.woniuxy.microsysserver.feign;

import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.http.MediaType;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;

/**
 * 针对某一个微服务提供的Feign接口
 * name = "micro-mall-server" 被调用方的spring.application.name的名称
 */
@FeignClient(name = "micro-mall-server")
public interface MicroMallServerFeign {
    /**
     * 从表单方式
     * @return
     */
    @GetMapping(value = "/commodity/all",produces = MediaType.APPLICATION_JSON_VALUE)
    String findAllCommodity();

    @RequestMapping(value = "/mall/getCurrentMouthSales",produces = MediaType.APPLICATION_JSON_VALUE)
    String getCurrentMouthSales();


}
